Skip to content

fix(tools): sync Slack customer-context source contract#162

Merged
leo-paz merged 2 commits into
mainfrom
codex/customer-context-contract-sync
Jul 20, 2026
Merged

fix(tools): sync Slack customer-context source contract#162
leo-paz merged 2 commits into
mainfrom
codex/customer-context-contract-sync

Conversation

@leo-paz

@leo-paz leo-paz commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add Slack to the generated customer-context source contract
  • update contract assertions
  • add a patch changeset for @outlit/tools

Why

Core PR #1569 exposes Slack as a customer-context search source. The SDK contract must match before the Core drift gate can pass.

Verification

  • bun run lint
  • bun run typecheck
  • bun run build
  • SDK CI-selected tools, CLI, and Pi tests
  • Core SDK tool-contract and OpenAPI drift checks
  • changeset validation

The broader local browser suite passed 132 tests and timed out only in the unrelated live Cal.com callback test.

Summary by CodeRabbit

  • New Features

    • Added Slack as a supported source for customer-context searches.
    • Slack is now accepted and validated alongside existing source types.
  • Documentation

    • Added release notes covering Slack support for customer-context searches.

@coderabbitai

coderabbitai Bot commented Jul 20, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 55 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 01103564-8ae6-475c-8517-e1927de8427a

📥 Commits

Reviewing files that changed from the base of the PR and between 4e0d0c9 and 4059656.

📒 Files selected for processing (1)
  • packages/tools/tests/client.test.ts

Walkthrough

Slack is added as a supported customer context source type in the tools contracts, validation expectations, runtime error output, contract hash, and patch release notes.

Changes

Customer context Slack support

Layer / File(s) Summary
Expand customer source contracts
packages/tools/src/contracts.ts
Adds SLACK to canonical and accepted customer source type arrays and updates the contract hash.
Update validation coverage and release metadata
packages/tools/tests/client.test.ts, .changeset/customer-context-slack-source.md
Updates source type expectations and validation messages, and records a patch release for Slack support.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

Poem

A bunny saw Slack join the source array,
And validation welcomed it there.
The hash hopped anew,
Tests followed through,
While release notes danced in the air.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is concise and accurately describes the main change: syncing the tools contract to support Slack as a customer-context source.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/customer-context-contract-sync

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
packages/tools/tests/client.test.ts (1)

115-130: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick win

Exercise Slack through the runtime validator.

These assertions verify the exported arrays, but not resolveCustomerContextSearchInput. Add a Vitest case that passes "slack" and asserts the returned request contains "SLACK"; otherwise the tests could pass while the actual normalization path rejects Slack.

As per coding guidelines, *.test.ts files should use Vitest.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/tools/tests/client.test.ts` around lines 115 - 130, Add a Vitest
test in the existing customer source type test area that calls
resolveCustomerContextSearchInput with the lowercase input "slack" and verifies
the returned request contains the canonical "SLACK" value. Keep the existing
exported-array assertions, and use Vitest APIs consistent with the surrounding
*.test.ts file.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@packages/tools/tests/client.test.ts`:
- Around line 115-130: Add a Vitest test in the existing customer source type
test area that calls resolveCustomerContextSearchInput with the lowercase input
"slack" and verifies the returned request contains the canonical "SLACK" value.
Keep the existing exported-array assertions, and use Vitest APIs consistent with
the surrounding *.test.ts file.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d768aa93-2d72-4824-9c13-20bb1f07fdad

📥 Commits

Reviewing files that changed from the base of the PR and between bd3fcf0 and 4e0d0c9.

📒 Files selected for processing (3)
  • .changeset/customer-context-slack-source.md
  • packages/tools/src/contracts.ts
  • packages/tools/tests/client.test.ts

@leo-paz
leo-paz merged commit a834b30 into main Jul 20, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant